﻿using nRoute.SiteMaps;
using nRoute.ViewModels;
using System.Collections.Generic;

namespace Officer2010.ViewModels
{
    [MapViewModel(typeof(Shell))]
    public class ShellViewModel
        : ViewModelBase
    {
        public ShellViewModel()
        {
            SiteMapService.LoadSiteMap((s) =>
            {
                if (s != null)
                {
                   SiteMapNodes = s.RootNode.ChildNodes;
                   NotifyPropertyChanged(() => SiteMapNodes);
                }
            });
        }

        public IEnumerable<SiteMapNode> SiteMapNodes { get; private set; }
    }
}
